package talk.Utils;

import java.util.ArrayList;
import java.util.List;

import talk.Bean.Chapter;
import talk.Bean.Course;
import talk.Data.Urls;

/**
 * Created by debby on 2018/5/25.
 * 描述:
 */

public class dataUtil {

    public static Course addList1(String name) {
        List<Chapter> chapterList = new ArrayList<>();
        Course course = new Course();
        course.setCourse(name);
        course.setChapterList(chapterList);
        //
        List<String> urls1 = new ArrayList<>();
        Chapter chapter1 = new Chapter();
        chapter1.setChapter("1-0 教学基本要求");
        chapter1.setUrlList(urls1);
        urls1.add(Urls.url1);
        urls1.add(Urls.url2);
        urls1.add(Urls.url3);
        urls1.add(Urls.url4);
        urls1.add(Urls.url5);
        chapterList.add(chapter1);
        //
        List<String> urls2 = new ArrayList<>();
        Chapter chapter2 = new Chapter();
        chapter2.setChapter("1-1 质点运动的描述");
        chapter2.setUrlList(urls2);
        urls2.add(Urls.url6);
        urls2.add(Urls.url7);
        urls2.add(Urls.url8);
        urls2.add(Urls.url9);
        urls2.add(Urls.url10);
        chapterList.add(chapter2);
        //
        List<String> urls3 = new ArrayList<>();
        Chapter chapter3 = new Chapter();
        chapter3.setChapter("1-2 圆周运动");
        chapter3.setUrlList(urls3);
        urls3.add(Urls.url11);
        urls3.add(Urls.url12);
        urls3.add(Urls.url13);
        urls3.add(Urls.url14);
        urls3.add(Urls.url15);
        urls3.add(Urls.url16);
        urls3.add(Urls.url17);
        chapterList.add(chapter3);
        //
        //
        List<String> urls4 = new ArrayList<>();
        Chapter chapter4 = new Chapter();
        chapter4.setChapter("1-3 相对运动");
        urls4.add(Urls.url3_1);
        urls4.add(Urls.url3_2);
        urls4.add(Urls.url3_3);
        urls4.add(Urls.url3_4);
        urls4.add(Urls.url3_5);
        chapter4.setUrlList(urls4);
        chapterList.add(chapter4);
        //
        return course;
    }


    public static Course addList2(String name) {
        List<Chapter> chapterList = new ArrayList<>();
        Course course = new Course();
        course.setCourse(name);
        course.setChapterList(chapterList);
        return course;
    }

    public static Course addList4(String name) {
        List<Chapter> chapterList = new ArrayList<>();
        Course course = new Course();
        course.setCourse(name);
        course.setChapterList(chapterList);
        //
        List<String> urls1 = new ArrayList<>();
        Chapter chapter1 = new Chapter();
        chapter1.setChapter("4-0 教学基本要求");
        chapter1.setUrlList(urls1);
        urls1.add(Urls.Chapter_4_0_1);
        urls1.add(Urls.Chapter_4_0_2);
        urls1.add(Urls.Chapter_4_0_3);
        urls1.add(Urls.Chapter_4_0_4);
        urls1.add(Urls.Chapter_4_0_5);
        chapterList.add(chapter1);
        //
        List<String> urls2 = new ArrayList<>();
        Chapter chapter2 = new Chapter();
        chapter2.setChapter("4-1 刚体的定轴转动");
        chapter2.setUrlList(urls2);
        urls2.add(Urls.Chapter_4_1_1);
        urls2.add(Urls.Chapter_4_1_2);
        urls2.add(Urls.Chapter_4_1_3);
        urls2.add(Urls.Chapter_4_1_4);
        urls2.add(Urls.Chapter_4_1_5);
        urls2.add(Urls.Chapter_4_1_6);
        urls2.add(Urls.Chapter_4_1_7);
        urls2.add(Urls.Chapter_4_1_8);
        chapterList.add(chapter2);
        //
        List<String> urls3 = new ArrayList<>();
        Chapter chapter3 = new Chapter();
        chapter3.setChapter("4-2 力矩 转动定律 转动惯量");
        chapter3.setUrlList(urls3);
        urls3.add(Urls.Chapter_4_2_1);
        urls3.add(Urls.Chapter_4_2_2);
        urls3.add(Urls.Chapter_4_2_3);
        urls3.add(Urls.Chapter_4_2_4);
        urls3.add(Urls.Chapter_4_2_5);
        urls3.add(Urls.Chapter_4_2_6);
        urls3.add(Urls.Chapter_4_2_7);
        chapterList.add(chapter3);
        //
        return course;
    }

}
